package com.ztgf.shopping.models.service.shop;

import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.IService;
import com.ztgf.common.constant.Result;
import com.ztgf.shopping.models.bo.shop.ShopShoppingCartBO;
import com.ztgf.shopping.models.bo.shop.ShopShoppingCartCmsBo;
import com.ztgf.shopping.models.bo.shop.ShopShoppingCartSaveBO;
import com.ztgf.shopping.models.dto.shop.ShopShoppingCartDTO;
import com.ztgf.shopping.models.vo.shop.ShopCommodityCartVO;
import com.ztgf.shopping.models.vo.shop.ShopShoppingCartCmsVO;
import com.ztgf.shopping.models.vo.shop.ShopShoppingCartVO;

import java.util.List;

/**
 * 用户购物车表服务
 *
 * @author zhanghualang
 * @Date 2020-05-27 14:05:12
 */
public interface IShopShoppingCartService extends IService<ShopShoppingCartDTO> {
    boolean add(ShopShoppingCartSaveBO saveBO);

    ShopShoppingCartVO queryShoppingCartPageList(ShopShoppingCartBO bo);

    List<ShopCommodityCartVO> queryHomePageList(ShopShoppingCartBO bo); //首页购物车

    void deleteByCid(Long shopId, Long commodityId, String attrIds); //购买后删除购物车记录

    boolean addToCartByOrderId(Long orderId);//再次购买

    boolean addBatch(String saveBOs); //批量加入购物车

    Result addByCms(String purchaseCommodityBargainIds);

    Page<ShopShoppingCartCmsVO> queryShoppingCartPageListByAdmin(ShopShoppingCartCmsBo bo);
}
